![]() | ![]() | ![]() | ![]() | ![]() |
When you try to subset a Google BigQuery table based on a Boolean variable, you might experience slow performance. This issue occurs because SAS® software does not have a Boolean data type, so it uses a numeric data type in which 1 is true and 0 is false. When SAS tries to pass the query to BigQuery, it includes the comparison syntax as entered in SAS. The BigQuery database expects to see variable = true and not variable = 1. This behavior results in BigQuery issuing an error similar to the following:
As a result of the BigQuery error, SAS removes the comparison in the second query that is passed to the database. If the query also included a join, order by, summarization, or a DISTINCT keyword, then that item might also be removed from the second query that is passed to the database. In most cases, the BigQuery error is not written to the SAS log to indicate that there was problem, so it is likely that there will be no indication that any of this has occurred. The SASTRACE output will incorrectly indicate that the query was processed by database.
Due to the probable increase in the number of rows being read and more of the processing of the query being done by SAS rather than in the database, the query might take longer than if all of the processing had been done by the database.
Product Family | Product | System | Product Release | SAS Release | ||
Reported | Fixed* | Reported | Fixed* | |||
SAS System | SAS/ACCESS Interface to Google BigQuery | Linux for x64 | V.03.05 | 2020.1.1 | Viya | Viya |
SAS System | SAS Data Connector to Google BigQuery | Linux for x64 | V.03.05 | 2020.1.1 | Viya | Viya |